package com.ruoyi.study.controller;

import com.ruoyi.common.core.web.controller.BaseController;
import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.study.service.IStyRedisStudyService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * redis信息Controller
 * 
 * @author dwb
 * @date 2024-09-04
 */
@RestController
@RequestMapping("/redisStudy")
public class StyRedisStudyController extends BaseController
{

    @Resource
    private IStyRedisStudyService styRedisStudyService;

    /**
     * 获取redis信息详细信息
     */
    @GetMapping(value = "/{getInfoByRedis}")
    public AjaxResult getInfoByRedis(@PathVariable("id") Long id)
    {
        return success(styRedisStudyService.styRedisCache(id));
    }
}
